import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const Test = () => import('../components/TestQuasar/test.vue')//这样属于路由懒加载
const ChangeTest = () => import('../components/TestQuasar/ChangeTest.vue')//这样属于路由懒加载
const HelloBase = () => import('../components/HelloWorld.vue')//这样属于路由懒加载
const Layout = () => import('../views/layout.vue')//这样属于路由懒加载
const Drawing = () => import('../views/Drawing.vue')//这样属于路由懒加载




const routes = [
  {
    path: '/',
    name: 'test',
    component: Test
  },
  {
    path: '/changetest',
    name: 'ChangeTest',
    component: ChangeTest
  },
  {
    path: '/hellobase',
    name: 'hellobase',
    component: HelloBase
  },
  {
    path: '/layout',
    name: 'layout',
    component: Layout
  },
  {
    path: '/drawing',
    name: 'drawing',
    component: Drawing
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
